﻿using Common;
using DAL.Product;
using Model.Product;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace BLL.Product
{
   public class ProductBLL
    {
       ProductDAL dal = new ProductDAL();
       /// <summary>
       /// 获取所有的数据信息
       /// </summary>
       /// <returns></returns>
       public List<ProductModel> GetList()
        {
            return dal.GetList();
        }
       /// <summary>
       /// 保存数据
       /// </summary>
       /// <param name="productModel"></param>
       /// <returns></returns>
       public int SaveData(ProductModel productModel) {
           return dal.SaveData(productModel);
       }
       /// <summary>
       /// 获取对象
       /// </summary>
       /// <param name="id"></param>
       /// <returns></returns>
       public ProductModel GetModel(string id) {
           return dal.GetModel(id);
       }
       /// <summary>
       /// 删除实体类信息
       /// </summary>
       /// <returns></returns>
       public ResultEntity DelModel(string id)
       {
           return dal.DelModel(id);
       }

    }
}
